import request from '@/utils/request'

// 查询区域预警列表
export function listDispatchAlarmArea(query) {
  return request({
    url: '/system/dispatchAlarmArea/list',
    method: 'get',
    params: query
  })
}

// 查询区域预警详细
export function getDispatchAlarmArea(alarmAreaId) {
  return request({
    url: '/system/dispatchAlarmArea/' + alarmAreaId,
    method: 'get'
  })
}

// 新增区域预警
export function addDispatchAlarmArea(data) {
  return request({
    url: '/system/dispatchAlarmArea',
    method: 'post',
    data: data
  })
}

// 修改区域预警
export function updateDispatchAlarmArea(data) {
  return request({
    url: '/system/dispatchAlarmArea',
    method: 'put',
    data: data
  })
}

// 删除区域预警
export function delDispatchAlarmArea(alarmAreaId) {
  return request({
    url: '/system/dispatchAlarmArea/' + alarmAreaId,
    method: 'delete'
  })
}
